package com.sbtr.business.classify.entity;

import io.swagger.annotations.ApiModelProperty;
import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;

import org.springframework.format.annotation.DateTimeFormat;
import com.fasterxml.jackson.annotation.JsonFormat;

import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import io.swagger.annotations.ApiModel;


/**
 * 算法版本字段列表 实体类
 *
 * @author dgl
 * @since 2023-06-13
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("a_algo_version_file")
@ApiModel(value="AlgoVersionFile对象")
public class AlgoVersionFile extends Model<AlgoVersionFile> {

    @TableId(value = "id")
    private Long id;

    @ApiModelProperty(value = "算法文件名称")
    private String fileName;

    @ApiModelProperty(value = "算法文件别名")
    private String fileAlias;

    @ApiModelProperty(value = "算法附件地址")
    private String fileUrl;

    @ApiModelProperty(value = "算法包大小")
    private String fileSize;

    @ApiModelProperty(value = "版本号")
    private String version;

    @ApiModelProperty(value = "下载累计次数")
    private Integer counts;

    @ApiModelProperty(value = "更新时间")
    @TableField(value = "update_time",fill = FieldFill.INSERT)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")// 后台传数据到前台
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") //前台传数据到后台
    private Date updateTime;

    @ApiModelProperty(value = "算法模板ID")
    private Long templateId;


    @Override
    protected Serializable pkVal() {
        return this.id;
    }
}
